package com.xuxin.baby.presenter;

import com.xuxin.baby.bean.BaseBean;
import com.xuxin.baby.contract.UserHistoryContract;
import com.xuxin.baby.database.HistoryBean;
import com.xuxin.baby.model.UserHistoryModel;
import java.util.List;
/**
 * Created by xu_xin
 * Created on 2020/11/13 0013
 * 历史足迹
 */
public class UserHistoryPresenter implements UserHistoryContract.Presenter {
    private  final UserHistoryModel model;
    private  final UserHistoryContract.View view;

    public UserHistoryPresenter(UserHistoryContract.View view) {
        this.view = view;
        model = new UserHistoryModel();
    }

    /**
     * 以下内容复用(用于请求完成后的操作)
     */
    @Override
    public void onError(BaseBean baseBean) {
        if (null != view) {
            view.onError(baseBean);
        }
    }

    @Override
    public void onComplete() {
        if (null != view) {
            view.onComplete();
        }
    }
}